package com.wxy.demo.tencent_cos;

import cn.hutool.core.io.FileUtil;

import java.io.File;
import java.io.IOException;

/**
 * <p>
 * 腾讯云带认证下载测试
 * </p>
 *
 * @author e-Xiaoyuan.Wang
 * @since 2023/1/16 17:19
 */
public class Main {
    public static void main(String[] args) throws IOException {
        TencentCosUtil tencentCosUtil = new TencentCosUtil();
        byte[] bytes = tencentCosUtil.downLoadFile("https://tce-1304962210.cos.ap-chongqing.myqcloud.com/tce-kbms/caa0850e-e3c9-4d62-aa9e-9fd0d55194a2.xlsx");
        FileUtil.writeBytes(bytes, new File("download/根据计划ID查询计划.xlsx"));
    }


}
